import {get, post, del, put} from "@/apis/http/request";
import {CronTriggers} from "@/apis/model/system/CronTriggersModel";


/**
* 得到列表
* @param params
*/
export const getCromTriggersList = (params: any) => get("/cronTriggers/list", params)

/**
* 得到分页列表
* @param params
*/
export const cromTriggersPage = (params: any) => post("/cronTriggers/page", params)

/**
* 删除数据
* @param id
* @returns
*/
export const deleteCromTriggersById = (id: number) => del("/cronTriggers/delete/"+ id)

/**
* 新增数据
* @param param
*/
export const insertCromTriggers = (param: CronTriggers) => post("/cronTriggers", param)

/**
* 更新数据
* @param param
*/
export const updateCromTriggers = (param: CronTriggers) => put("/cronTriggers", param)

/**
 * 切换数据状态
 * @param param
 */
export const updateCronSwitch = (param: CronTriggers) => post('/cronTriggers/switchStatus',param)